package com.bawei.hgshop.entity;

import java.io.Serializable;
import java.util.List;

/**
 *    规格 比如：内存  尺寸  长短  
 * @时间  2021-1-12  8:43:40
 *
 */
public class Spec  implements Serializable{
	
	/**
	 * 
	 */
	private static final long serialVersionUID = 7810790956812817102L;
	private int id;
	private String specName;
	
	List<SpecOption> options;
	
	
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}
	public String getSpecName() {
		return specName;
	}
	public void setSpecName(String specName) {
		this.specName = specName;
	}
	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + id;
		result = prime * result + ((specName == null) ? 0 : specName.hashCode());
		return result;
	}
	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		Spec other = (Spec) obj;
		if (id != other.id)
			return false;
		if (specName == null) {
			if (other.specName != null)
				return false;
		} else if (!specName.equals(other.specName))
			return false;
		return true;
	}
	
	
	public List<SpecOption> getOptions() {
		return options;
	}
	public void setOptions(List<SpecOption> options) {
		this.options = options;
	}
	@Override
	public String toString() {
		return "Spec [id=" + id + ", specName=" + specName + "]";
	}
	
	
	
}
